# the minimum version of CMake.
cmake_minimum_required(VERSION 3.10.2)

project("libyuv")

set(CMAKE_C_FLAGS "-std=c99 -Wno-typedef-redefinition")

add_library(libyuv
            SHARED
            native-lib.cpp
            libyuv/compare.cc
                libyuv/compare_common.cc
                libyuv/compare_neon64.cc
                libyuv/compare_gcc.cc
                libyuv/convert.cc
                libyuv/convert_argb.cc
                libyuv/convert_from.cc
                libyuv/convert_from_argb.cc
                libyuv/convert_to_argb.cc
                libyuv/convert_to_i420.cc
                libyuv/cpu_id.cc
                libyuv/planar_functions.cc
                libyuv/rotate.cc
                libyuv/rotate_argb.cc
                libyuv/rotate_mips.cc
                libyuv/rotate_neon64.cc
                libyuv/row_any.cc
                libyuv/row_common.cc
                libyuv/row_mips.cc
                libyuv/row_neon64.cc
                libyuv/row_gcc.cc
                libyuv/scale.cc
                libyuv/scale_any.cc
                libyuv/scale_argb.cc
                libyuv/scale_common.cc
                libyuv/scale_mips.cc
                libyuv/scale_neon64.cc
                libyuv/scale_gcc.cc
                libyuv/video_common.cc


)

include_directories(${CMAKE_CURRENT_SOURCE_DIR}/libyuv/libyuv)


set(LIBS)
list(APPEND LIBS
    hilog_ndk.z
)

target_link_libraries(libyuv ${LIBS})